<!DOCTYPE html> 
<html lang="en"> 
    <head> 
		<title>Stack Exchange Election Nominee Information</title>
		<link rel="shortcut icon" href="favicon.ico" />
		<link href="style.css" type="text/css" rel="stylesheet" /> 
	</head> 
	<body> 
		<div id="header"> 
			<h1>Stack Exchange Moderator Candidate Statistics</h1> 
			
			<p id="intro">This page was put together by 
           <a href="http://meta.stackoverflow.com/users/150097/yi-jiang">Yi Jiang</a> and
           <a href="http://meta.stackoverflow.com/users/150235/tim-stone">Tim Stone</a>.
			The statistics are loaded dynamically from your browser - please be patient, the loading times are quite long. 
			The statistics are presented as is, it is up to you to decide what their relative importance is. 
			The Noteworthy Badges are those which we consider to be relevant to the role of a moderator. 
			If you have any comments, suggestions, or see any bugs, please post on the Stack Apps question
			<a href="http://stackapps.com/questions/2049/stack-exchange-elections-statistics-page">
         <strong>Stack Exchange Elections Statistics Page</strong></a></p>
			
			<div id="option-menu">
				<h3>Which badges to show</h3>
				<ul id="default-tag-list">
				</ul>
				
				<form class="add-things"><label for="add-badge">Add badge</label>
					<input type="text" id="add-badge" />
				</form>
				
				<p id="badge_suggestions_list">
				</p>
			</div>

			<div id="loading-sites">
				<h2>Please bear with us while we</h2> 
				<ul>
					<li><del>Commit vote fraud</del></li>
					<li><del>Drop everything and use jQuery</del></li>
					<li><del>Load animated dancing unicorns</del></li>
					<li><del>Bring about world peace, solve world hunger and cure cancer</del></li>
					<li>Retrieve list of sites with ongoing and completed elections</li>
				</ul>
			</div>
			
			<div id="sitelist"> 
				<h2>Choose your site</h2>
				<ul id="current-elections">

				</ul>
				
				<h3>Completed Elections</h3>
				<ul id="completed-elections">

				</ul>
				
				<a id="option-menu-toggle" href="#">Change Noteworthy Badges</a>
			</div>
			
			<h2 id="loading">Please wait, Reticulating Splines</h2> 
			<ul id="loading-list">							
				<li id="load-init" class="load-elections">Loading elections page</li> 
				<li id="load-profile" class="load-elections">Loading user profile on main site</li> 
				<li id="load-tag">Loading user tag information</li> 
				<li id="load-badge">Loading badge information</li> 
				<li id="load-meta">Loading Meta profiles</li> 
				<li id="load-activity">Loading user activity</li> 
			</ul> 
		</div> 
		
		<div id="sort">
			<form>
				<h2>Sort by: </h2> 
				<label class="active"><input type="radio" value="random" name="sort" checked="checked" /> Random</label><label> 
				<input type="radio" value="reputation" name="sort" /> Reputation</label><label> 
				<input type="radio" value="join" name="sort" /> Join date</label><label>
				<input type="radio" value="nomination" name="sort" /> Nomination time</label>
			</form><form>
				<h2>Show: </h2>
				<label class="active"><input type="radio" value="blurb" name="show" checked="checked" /> Nomination</label><label> 
				<input type="radio" value="profile" name="show" /> Profile</label><label> 
				<input type="radio" value="none" name="show" /> None</label>
			</form>
		</div>
		
		<div id="site-detail">
			<img src="" alt="" class="site-logo" />
			<div class="site-right">
				<h2 class="site-title"></h2>
				<dl>
					
				</dl>
				<a href="#" id="sitelist-toggle">Change Site</a>
				<a href="#" id="add-user-toggle">Add more users</a>
				<a href="#" class="election-link">Elections page on actual site</a>
			</div>
			<div id="election-result">
				<h2>This election has ended. These are your new moderators!</h2>
			</div>
		</div>
		
		<div id="add-user">
			<form class="add-things">
				<label for="user-search">Find user: </label>
				<input type="text" id="user-search" />
			</form>
			
			<ul id="add-user-list">
				
			</ul>
			
			<h3>Selected users</h3>
			<ul id="selected-user-list">
				
			</ul>
			
			<a id="add-user-confirm" href="#">Add users</a>
		</div>
		
		<ul id="user-list"> 
		</ul> 
		
		<div id="footer"> 
			Created by <a href="http://meta.stackoverflow.com/users/150097/yi-jiang">Yi Jiang</a>.
			Powered by the <a href="http://stackapps.com">Stack Exchange API</a>, <a href="http://www.jquery.com">jQuery</a> and <a id="unicorn" href="#">unicorns</a>.
		</div> 
		
		<script id="userInitTemplate" type="text/html"> 
		<li id="user_${user_id}" data-association="${account_id}" data-nomination-order="${nominated_order}">
			<div class="leftCol">
				<a href="http://${Settings.siteName}.com/users/${user_id}">
					<img class="gravatar" src="${profile_image}" alt="${display_name}'s gravatar" />
				</a>
				{{if user_type === 'moderator' && Settings.phase === 'completed'}}
					<p class="elected"><span class="diamond">&diams; </span>Elected</p>
				{{/if}}
			</div>
			<div class="rightCol">
				<h2>${display_name}</h2> <p class="personal">{{html personal_data}}</p>
				<p class="soInfo">
					<span class="rep" title="${reputation}">${rep_string}</span>
					<span class="badges">
						<span class="gold">${badge_counts.gold}</span>
						<span class="silver">${badge_counts.silver}</span>
						<span class="bronze">${badge_counts.bronze}</span>
					</span>
					<span class="member_for" title="Member Since: ${creation_string}">member for: ${member_for}</span>
					{{if user_type === 'moderator' && Settings.phase !== 'completed'}}
						<span title="This user is a Pro Tem (Provisional) Moderator on this site" class="pro-tem">Pro Tem</span>
					{{/if}}
				</p>
				<p class="tag_list"></p>
				
				<div class="nomination_detail blurb">{{html user_text}}</div>
				<div class="nomination_detail profile">{{html about_me}}</div>
				
				<div class="site_stats">
					<h3>Statistics</h3>
					<p>Answers/Questions: <span class="stats" title="Ratio: ${ (answer_count/question_count).toFixed(2) }">${ answer_count + ' / ' + question_count }</span></p>
					<p>Upvote/Downvote: <span class="stats" title="Ratio: ${ (up_vote_count/down_vote_count).toFixed(2) }">${ up_vote_count + ' / ' + down_vote_count }</span></p>
					<p><span title="Both of these are naive average, and does not take into account other means of rep changes like bounties">Avg. Rep.</span> Per Post:
					<span class="stats">${ (reputation / (answer_count + question_count)).toFixed(1) }</span></p>
					<p><span title="Both of these are naive average, and does not take into account other means of rep changes like bounties">Avg. Rep.</span> Per Day:
					<span class="stats">${ (reputation / days_active).toFixed(1) }</span></p>
					<a href="http://${Settings.siteName}.com/users/${user_id}">View Profile</a>
				</div>
				
				<div class="site_stats meta">
					<h3>Meta Participation</h3>
				</div>
				
				<div class="site_stats stackexchange">
					<h3>Stack Exchange Participation</h3>
				</div>
				
				<div class="second_row">
					<div class="site_stats badge_list">
						<h3>Noteworthy Badges</h3>
						<ul></ul>
					</div>
					<div class="recent_activity">
						<h3>Recent Activity</h3>
						<ul>
						</ul>
					</div>
				</div>
			</div>
		</li>
		</script> 
		
		<script id="userTagTemplate" type="text/html"> 
		<a href="http://${Settings.siteName}.com/search?q=user:${user_id}+[${name_safe}]">${name}</a>
		</script> 
		
		<script id="metaTemplate" type="text/html"> 
		{{if Settings.siteName.indexOf('stackoverflow') === 0}}
		<p>Reputation: <span class="stats" title="${reputation}">${rep_string}</span></p>
		{{/if}}
		<p>Badges:
			<span class="badges stats">
				<span class="gold">${badge_counts.gold}</span>
				<span class="silver">${badge_counts.silver}</span>
				<span class="bronze">${badge_counts.bronze}</span>
			</span>
		</p>
		<p>Answers/Questions: <span class="stats" title="Ratio: ${ (answer_count/question_count).toFixed(2) }">${ answer_count + ' / ' + question_count }</span></p>
		<a href="http://meta.${Settings.siteName}.com/users/${user_id}">View Meta Profile</a>
		</script> 
		
		<script id="stackExchangeTemplate" type="text/html"> 
		<p>Participated sites (<span title="Active defined as having more than 200 reps on that site">active</span>): <span class="stats">${total_sites} (${active_sites})</span></p>
		<p><span title="Number excludes 100 rep association bonus">Total Reputation:</span> <span class="stats" title="${combined_rep}">${combined_rep_string}</span></p>
		</script> 
		
		<script id="timelineTemplate" type="text/html"> 
		<li>
			<div class="timeline_event">
				<p class="action">${action}</p>
				<p title="${creation_string}">${time_ago}</p>
			</div>
			<div class="timeline_detail">
				{{if action === 'awarded'}}
                
				<h4><a href="${link}">${title} badge</a></h4>
				<p>${detail}</p>
				
				{{else}}
				
				<h4><a href="${link}">${title}</a></h4>
				<p>{{html Markdown.parse(detail)}}</p>
				
				{{/if}}
			</div>
		</li>
		</script>
		
		<script id="defaultBadgeTemplate" type="text/html">
		<li>
			<span class="badge-name ${rank}">${name}</span> ${description} <a href="#" class="badge-list-remove">remove</a>
		</li>
		</script>
		
		<script id="primaryVote" type="text/html">
		<div class="primary">
			<p class="score" title="Up/Down Ratio: ${ (up_vote_count/ down_vote_count).toFixed(2) }">${score}</p>
			<p class="votes"><span class="upvote">+${up_vote_count}</span> / <span class="downvote">-${down_vote_count}</span></p>
			<p class="primary-sub">Primary votes</p>
			
			<p class="top10" title="Top 10 candidates from the Primary phase will move on to the Election stage">Top<span class="ten">10</span></p>
		</div>
		</script>
		
		<script id="userInfoBox" type="text/html">
		<li>
			<img src="${profile_image}&s=32" alt="${display_name}'s gravatar" />
			<div class="infobox-right">
				<h4>${display_name}</h4>
				<p class="infobox-stats">
					<span class="rep" title="${reputation}">${rep_string}</span>
					<span class="badges">
						<span class="gold">${badge_counts.gold}</span>
						<span class="silver">${badge_counts.silver}</span>
						<span class="bronze">${badge_counts.bronze}</span>
					</span>
				</p>
			</div>
		</li>
		</script>
		
		<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js" type="text/javascript"></script>
        <script src="/es5-shim.min.js"></script>
        <script src="/meddle.js"></script>
		<script src="badges.js" type="text/javascript"></script>
		<script src="plugins.js" type="text/javascript"></script>
		<script src="master.js" type="text/javascript"></script> 	
	</body> 
</html>

